
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>	
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.thymeleaf.org">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>培训计划反馈</title>
    <link href="${pageContext.request.contextPath }/static/css/tail.css" rel="stylesheet" type="text/css" />
    <link href="${pageContext.request.contextPath }/static/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
	
    <script type="text/javascript" src="${pageContext.request.contextPath }/static/js/jquery.js"></script>
    <script>
        function change() {
            var height01 = $(window).height();
            $(".top").css('height', height01 - 35+"px");
        }
    </script>
</head>

<body style="border-radius: 8px" onload="change()">
<div class="title"><h2>培训管理》培训计划管理》培训计划反馈</h2></div>

 <form id="form_demo"  method="get" action="../CvSaveFk.json" >
<div class="top">
    <div>
        <div class="top_out">
        	<input style="display: none;" name = "id" id="id" value="${cps.id }">
            <table class="table" >
                <tbody>
               
                <tr>
                	<td>培训名称:</td>
                    <td colspan = "5" style="text-align: left"><input type="text"  name="trainName" value="${cps.trainName }" > </td>
                </tr>
                <tr>
                    <td>培训讲师：</td>
                    <td  style="text-align: left"><input type="text"  name="trainLecturer" value="${cps.trainLecturer }"></td>
                    <td>培训时间：</td>
                    <td style="text-align: left"><input id="demo01" type="text" class="startTime" name="startTime" value="${cps.startTime }"></td>
                	<td style="text-align: center;">至</td>
                	<td><input id="demo02" type="text" class="overTime" name="overTime" value="${cps.overTime }"></td>
                </tr>
                <tr>
                    <td style="line-height: 140px">培训目的:</td>
                    <td colspan = "5" style="text-align: left"><textarea style="width: 100%;height: 150px" name="trainGoal">${cps.trainGoal }</textarea> </td>
                </tr>
                <tr>
                    <td style="line-height: 140px">参训人员：</td>
                    <td colspan = "5" style="text-align: left"><textarea style="width: 100%;height: 150px" name="attendees">${cps.attendees }</textarea></td>
                </tr>
                <tr>
                    <td style="line-height: 140px">培训简介：</td>
                    <td colspan = "5" style="text-align: left"><textarea  id="note" style="width: 100%;height: 150px" name="trainIntro" >${cps.trainIntro }</textarea></td>
                </tr>
                <tr>
                	<td>上传附件</td>
                	<td  colspan = "2"><input type="file" name="filepath" /></td>
                </tr>
                <tr>
                	<td colspan = "6">————————————————培训反馈————————————————————————————————————————————————————————————————————</td>
                </tr>
                <tr>
                	<td>培训反馈:</td>
                	<td><select name="feedback" id ="feedback">
                			<option value="0">--请选择--</option>
                		<c:forEach var="c" items="${cpf }">
                				<option <c:if test="${c.id == cps.feedback}">selected="selected"</c:if> value="${c.id }">${c.feedback }</option>
                		</c:forEach>
                	</select> </td>
                </tr>
               <tr>
                    <td style="line-height: 140px">培训总结：</td>
                    <td colspan = "5" style="text-align: left"><textarea id ="summary" style="width: 100%;height: 150px" name="summary">${cps.summary }</textarea></td>
                </tr>
                <tr>
                    <td style="line-height: 140px">考核结果：</td>
                    <td colspan = "5" style="text-align: left"><textarea id ="result" style="width: 100%;height: 150px" name="result">${cps.result }</textarea></td>
                </tr>
                </tbody>
            </table>
        </div>
        
    </div>
    <div class="bot_btn">
       	<input class="btn" type="button" onclick="CvSaveFk()" value="保存" /> 
        <button class="btn btn1"><a href="#" onClick="javascript :history.back(-1);" target="right">返回</a></button>
    </div>
</div>
</form>
</body>

<script src="${pageContext.request.contextPath }/static/js/date/js/laydate.js"></script>
<script>
    !function(){
        laydate.skin('molv');
        laydate({elem: '#demo'});
        laydate({elem: '#demo01'});
        laydate({elem: '#demo02'});
    }();
    //保存
    function CvSaveFk() {
		var id = $('#id').val();
		var feedback = $('#feedback').val();
		var summary = $('#summary').val();
		var result = $('#result').val();
		$.ajax({
			url : '../CvSaveFk.json',
			type : 'GET',
			data : {
				"id":id,
				"feedback":feedback,
				"summary":summary,
				"result":result
			},
			dataType : 'json',
			success : function(a) {
	        	if(a.result){
	        		alert("保存成功!");
	        		window.location.href = '../GetCvP.html';
	        	}else{
	        		alert("保存失败!");
	        	} 
	      }	
		})
	}
</script>
<script>
	
</script>

<script type="text/javascript" src="${pageContext.request.contextPath }/static/js/jquery.js"></script>
</html>












